home *** CD-ROM | disk | FTP | other *** search
- on startMovie
- global pictNum, maxPicts
- if (the memorysize / 1024) < 3520 then
- set the visible of sprite 11 to 0
- set the visible of sprite 12 to 0
- set the visible of sprite 13 to 0
- set the visible of sprite 14 to 0
- set maxPicts to 8
- else
- set maxPicts to 12
- end if
- set HC to the number of cast "handCursor"
- cursor([HC, HC + 1])
- set pictNum to the number of cast "pict1"
- end
-
- on readPicts fileNum, order
- global pictFolder, skObj, maxPicts
- set pict to 1
- repeat while pict <= maxPicts
- set fileName to getNthFileNameInFolder(pictFolder, fileNum)
- if fileName = EMPTY then
- repeat with i = pict to maxPicts
- set the picture of cast ("pict" & i) to the picture of cast "blank"
- put EMPTY into line i of field "pictFiles"
- end repeat
- set pict to maxPicts + 1
- else
- if fileName starts "pict" then
- if the machineType = 256 then
- set result to skObj(mFileToCast, pictFolder & fileName)
- else
- set temp to FileIO(mnew, "read", pictFolder & fileName)
- if objectp(temp) then
- set result to temp(mReadPICT)
- else
- set result to 0
- end if
- end if
- if value(result) = 0 then
- alert("Error " & result & " reading from File: " & fileName)
- set the picture of cast ("pict" & pict) to the picture of cast "blank"
- put EMPTY into line pict of field "pictFiles"
- else
- set offset to (pict - 1) mod 4
- puppetSound(the name of cast (the number of cast "marimba1" + offset))
- updateStage()
- set the picture of cast ("pict" & pict) to result
- put fileName into line pict of field "pictFiles"
- end if
- if objectp(temp) then
- temp(mdispose)
- end if
- set pict to pict + 1
- end if
- end if
- if order = #ascending then
- set fileNum to fileNum + 1
- next repeat
- end if
- if order = #descending then
- set fileNum to fileNum - 1
- end if
- end repeat
- return fileNum
- end
-
- on selectPict
- global pictNum
- puppetSprite(2, 1)
- puppetSound("Piano Chord C Major")
- set the locH of sprite 2 to the locH of sprite the clickOn
- set the locV of sprite 2 to the locV of sprite the clickOn
- set pictNum to the castNum of sprite the clickOn
- updateStage()
- end
-